package com.biz.primus.model.promotion.vo;

import com.biz.primus.model.promotion.enums.PromotionPaymentChannelEnum;
import com.biz.primus.base.enums.PromotionTypeEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.List;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 订单促销详情Vo
 *
 * @author david-liu
 */
@Getter
@Setter
@ApiModel(value = "订单促销详情")
@NoArgsConstructor
public class OrderPromotionDetailVo implements Serializable {
    private static final long serialVersionUID = 3203002164815220854L;

    /**
     * 促销ID
     */
    @ApiModelProperty(value = "促销ID")
    private Long id;

    /**
     * 促销名字
     */
    @ApiModelProperty(value = "促销名字")
    private String name;

    /**
     * 促销描述
     */
    @ApiModelProperty(value = "促销描述")
    private String description;

    /**
     * 是否支持使用优惠券
     */
    @ApiModelProperty(value = "是否支持使用优惠券")
    private Boolean allowCoupon;

    /**
     * 促销类型
     */
    @ApiModelProperty(value = "促销类型")
    private PromotionTypeEnum promotionType;

    /**
     * 促销支付渠道限制
     */
    @ApiModelProperty(value = "促销限制的支付类型")
    private PromotionPaymentChannelEnum paymentChannelLimit;

    /**
     * 受促销影响商品ID集合
     */
    @ApiModelProperty(value = "受促销影响的商品ID集合")
    private List<Long> effectProductIds;

    /**
     * 如果买赠促销, 赠品的数量
     */
    @ApiModelProperty(value = "赠品数量")
    private Long giftQuantity;

    /**
     * 赠品ID
     */
    @ApiModelProperty(value = "赠品ID")
    private Long giftProductId;

    /**
     * 减免金额
     */
    @ApiModelProperty(value = "减免金额")
    private Integer cutAmount;

    @ApiModelProperty(value = "折扣促销商品信息")
    private List<DiscountProductVo> discountProducts;

    @ApiModelProperty(value = "加价换购商品信息")
    private RedemptionProductVo redemptionProductVo;

    @ApiModelProperty(value = "买赠信息")
    private PurchaseGiftVo purchaseGift;

    @ApiModelProperty(value = "商品降价信息(如果促销类型是降价拍, 会返回每个商品降价多少)")
    private List<ProductCutPriceVo> productCutPrices;

    @ApiModelProperty(value = "下单有礼礼品信息")
    private LuckyOrderPromotionGiftVo luckyOrderPromotionGift;

    @Override
    public String toString() {
        return ToStringBuilder.reflectionToString(this, ToStringStyle.JSON_STYLE);
    }
}
